import request from '@/utils/request'

export function login(data) {
  return request({
    url: '/admin-user-no-login/login',
    method: 'post',
    data
  })
}

export function getInfo(token) {
  return request({
    url: '/admin-user/info',
    method: 'get'
  })
}

export function getDetail(data) {
  return request({
    url: '/admin-user/detail',
    method: 'post',
    data
  })
}

export function logout() {
  return request({
    url: '/admin-user-no-login/logout',
    method: 'post'
  })
}

export function create(data) {
  return request({
    url: '/admin-user/create',
    method: 'post',
    data
  })
}

export function edit(data) {
  return request({
    url: '/admin-user/edit',
    method: 'post',
    data
  })
}

export function getList(data) {
  return request({
    url: '/admin-user/list',
    method: 'post',
    data
  })
}

export function del(data) {
  return request({
    url: '/admin-user/del',
    method: 'post',
    data
  })
}
